@extends('layouts.master')
@section('head')
	@parent
	<title>FACT - Create Event</title>

	<script type="text/javascript" src="/js/jq/jquery-ui.js"></script>
	<link rel="stylesheet" type="text/css" href="/js/jq/jquery-ui.css" media="screen" />
	<script>
		$(function() {
			$("#datepicker").datepicker({dateFormat: 'yy-mm-dd',
				onSelect: function(dateText, inst) {
					var d = $(this).datepicker("getDate");
				}
			});
		});
	</script>
@stop

@section('content')
	<div class="container-fluid">
	<div class="row">
		<div class="col-md-8 col-md-offset-2">
			<div class="panel panel-default" style="margin-top: 86px;">
				<div class="panel-heading">Add Event</div>
				<div class="panel-body">
					<!-- add action -->
					<form class="form-horizontal" role="form" method="POST" action="/events" enctype="multipart/form-data">
						<input type="hidden" name="_token" value="{{ csrf_token() }}">

						<div class="form-group">
							<label class="col-md-4 control-label">Title</label>
							<div class="col-md-6">
								<input type="text" class="form-control" name="title" value="">
							</div>
						</div>

						<div class="form-group">
							<label class="col-md-4 control-label">Description</label>
							<div class="col-md-6">
								<textarea type="text" class="form-control formarea" name="description" value=""></textarea>
							</div>
						</div>
						
						<!-- <div class="form-group">
							<label class="col-md-4 control-label">Location</label>
							<div class="col-md-6">
								<input type="text" class="form-control" name="location" value="">
							</div>
						</div> -->

						<div class="form-group">
							<label class="col-md-4 control-label">Image</label>
							<div class="col-md-6">
								<input type="file" style="margin-top: 8px;" name="image" value="{{ old('image') }}">
							</div>
						</div>

						<div class="form-group">
							<label class="col-md-4 control-label">Date</label>
							<div class="col-md-6 height">
								<input type="text" id="datepicker" class="form-control" name="date" value="">
							</div>
						</div>

						<div class="form-group">
							<label class="col-md-4 control-label">Time</label>
							<div class="col-md-6">
								<input type="text" class="form-control" name="time" value="">
							</div>
						</div>
						<div class="form-group">
							<div class="col-md-6 col-md-offset-4">
								<button type="submit" class="btn btn-primary">
									Add Event
								</button>
							</div>
						</div>
					</form>
				</div>
			</div>
		</div>
	</div>
</div>
@stop